## Copyright 2002-2004 Andrew Loewenstern, All Rights Reserved
## Copyright 2007 Roee Shlomo, All Rights Reserved
# see LICENSE.txt for license information

###  BitTorrent
BUILD_NUMBER = 100
TOKEN_UPDATE = 60 * 5 # five minutes

###  Kademlia
CHECKPOINT_INTERVAL = 60 * 15 # fifteen minutes
HASH_LENGTH = 160
NULL_ID =  20 * '\0'
K = 8

### SEARCHING/STORING
CONCURRENT_REQS = 4
STORE_REDUNDANCY = 3

###  ROUTING TABLE STUFF
MAX_FAILURES = 5
MIN_PING_INTERVAL = 60 * 15 # fifteen minutes
BUCKET_STALENESS = 60 * 15 # fifteen minutes

###  KEY EXPIRER
KEINITIAL_DELAY = 15 # 15 seconds
KE_DELAY = 60 * 10 # 10 minutes
KE_AGE = 60 * 30 # 30 minutes

###  KRPC
KRPC_TIMEOUT = 30
NUM_EVENTS = 3
KRPC_ERROR = 1
KRPC_ERROR_METHOD_UNKNOWN = 2
KRPC_ERROR_RECEIVED_UNKNOWN = 3
KRPC_ERROR_TIMEOUT = 4
TID = 't'
REQ = 'q'
RSP = 'r'
TYP = 'y'
ARG = 'a'
ERR = 'e'
VER = 'v'
